//
//  PKLeftView.m
//  PianKe
//
//  Created by lanou on 15/9/26.
//  Copyright (c) 2015年 lanou. All rights reserved.
//

#import "PKLeftView.h"

@implementation PKLeftView

/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/
-(instancetype)initWithFrame:(CGRect)frame
{
    self=[super initWithFrame:frame];
    if (self) {
        _peopleImageButton=[UIButton buttonWithType:UIButtonTypeSystem];
        _peopleImageButton.frame=CGRectMake(0, 0, 50, 50);
        [_peopleImageButton.layer setCornerRadius:25];
        _peopleImageButton.backgroundColor=[UIColor yellowColor];
        [self addSubview:_peopleImageButton];
        _accountButton =[UIButton buttonWithType:UIButtonTypeSystem];
        _accountButton.frame=CGRectMake(65, 20, 40, 30) ;
        [_accountButton setTitle:@"登陆" forState:UIControlStateNormal];
        [self addSubview:_accountButton];
        _label=[[UILabel alloc]initWithFrame:CGRectMake(110, 20, 10, 30)];
        _label.text=@"|";
        [self addSubview:_label];
        _registButton =[UIButton buttonWithType:UIButtonTypeSystem];
        _registButton.frame=CGRectMake(125, 20, 40, 30);
        [_registButton setTitle:@"注册" forState:UIControlStateNormal];
        [self addSubview:_registButton];
        _downloadButton=[UIButton buttonWithType:UIButtonTypeSystem];
        _downloadButton.frame=CGRectMake(20, 70, 40, 30);
        _downloadButton.backgroundColor=[UIColor yellowColor];
        [self addSubview:_downloadButton];
        _collectionButton=[UIButton buttonWithType:UIButtonTypeSystem];
        _collectionButton.frame=CGRectMake(70, 70, 40, 30);
            _collectionButton.backgroundColor=[UIColor yellowColor];
        [self addSubview:_collectionButton];
        _messageButton=[UIButton buttonWithType:UIButtonTypeSystem];
        _messageButton.frame=CGRectMake(120, 70, 40, 30);
            _messageButton.backgroundColor=[UIColor yellowColor];
        [self addSubview:_messageButton];
        _writeButton=[UIButton buttonWithType:UIButtonTypeSystem];
        _writeButton.frame=CGRectMake(170, 70, 40, 30);
            _writeButton.backgroundColor=[UIColor yellowColor];
        [self addSubview:_writeButton];
        _searchBar =[[UISearchBar alloc]initWithFrame:CGRectMake(20, 120, 200, 30)];
        _searchBar.backgroundColor=[UIColor greenColor];
        [self addSubview:_searchBar];
        
        
        
        
        
    }
    return self;
}
@end
